package top.yuhaitao.core.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import top.yuhaitao.core.mybatis.dbo.TUser;
import top.yuhaitao.core.mybatis.mapper.TUserMapper;
import top.yuhaitao.core.pojo.ProductInfo;
import top.yuhaitao.core.repository.ProductInfoRepository;
import top.yuhaitao.core.service.SecondKillSevice;
import top.yuhaitao.core.service.UserSevice;
import top.yuhaitao.core.util.RedisLock;

import javax.annotation.Resource;
import java.util.Optional;

/**
 * 用户测试
 */
@Service
@Transactional
public class UserServiceImpl implements UserSevice {

    @Resource
    private TUserMapper tUserMapper;


    @Override
    public TUser getUser(Long id) {
        return tUserMapper.selectByPrimaryKey(id);
    }

}
